//
//  XiangqingFooterView.m
//  B段项目
//
//  Created by 徐茂怀 on 15/11/4.
//  Copyright © 2015年 徐茂怀. All rights reserved.
//

#import "XiangqingFooterView.h"
#import "FitHeader.h"
@implementation XiangqingFooterView

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self createView];
    }
    return self;
}

-(void)createView
{
    _timeLabel = [[UILabel alloc]init];
    _renshuLabel = [[UILabel alloc]init];
    _xiaoTieShiLabel = [[UILabel alloc]init];
    _xiaoTieShiLabel.text = @"小贴士";
    _xiaoTieShiLabel.textColor = [UIColor colorWithRed:0.28 green:0.63 blue:0.59 alpha:1];
    _xiaoTieShiLabel.font = [UIFont fontWithName:@"Helvetica-Bold" size:17 * FitWidth];
    _contentLabel = [[UILabel alloc]init];
    _contentLabel.numberOfLines = 0;
    
    [self addSubview:_timeLabel];
    [self addSubview:_renshuLabel];
    [self addSubview:_xiaoTieShiLabel];
    [self addSubview:_contentLabel];
}

-(void)layoutSubviews
{
    [super layoutSubviews];
    _timeLabel.frame = CGRectMake(10 * FitWidth, 10 * FitHeight, 200 * FitWidth, 45 * FitHeight);
    _renshuLabel.frame = CGRectMake(_timeLabel.frame.origin.x, _timeLabel.frame.origin.y + _timeLabel.frame.size.height + 10 * FitHeight, 200 * FitWidth, 45 * FitHeight);
    _xiaoTieShiLabel.frame = CGRectMake(_renshuLabel.frame.origin.x, _renshuLabel.frame.origin.y + _renshuLabel.frame.size.height + 10 * FitHeight, 100 * FitWidth, 30 * FitHeight);
    _contentLabel.frame = CGRectMake(_xiaoTieShiLabel.frame.origin.x, _xiaoTieShiLabel.frame.origin.y + _xiaoTieShiLabel.frame.size.height + 5 * FitHeight, 335 * FitWidth, self.frame.size.height - 175 * FitHeight);
}

@end
